package com.atguigu.gulimall.order.web;

import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @Description
 * @Author lhj
 * @Date 2024/4/22 22:14
 */
@Slf4j
@Controller
public class PageController {
    
    @GetMapping("/{page}.html")
    public String listPage(@PathVariable String page) {
        log.info("PageController.listPage receive request parameters: {}", page);
        return page;
    }

    @ResponseBody
    @GetMapping("/")
    public String index() {
        return "hello";
    }
    
}
